import request from '@/utils/request'

// 查询告示列表
export function listContent(query) {
  return request({
    url: '/admin/content/list',
    method: 'get',
    params: query
  })
}

// 查询告示详细
export function getContent(id) {
  return request({
    url: '/admin/content/' + id,
    method: 'get'
  })
}

// 新增告示
export function addContent(data) {
  return request({
    url: '/admin/content',
    method: 'post',
    data: data
  })
}

// 修改告示
export function updateContent(data) {
  return request({
    url: '/admin/content',
    method: 'put',
    data: data
  })
}

// 删除告示
export function delContent(id) {
  return request({
    url: '/admin/content/' + id,
    method: 'delete'
  })
}
// 新增、修改的区域下拉框
export function getContentArea() {
  return request({
    url: '/admin/area/allList',
    method: 'get'
  })
}
